package com.yj.timecapsule.mapper;

import com.yj.timecapsule.entity.user.Friends;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface FriendsMapper {
    int deleteByPrimaryKey(Long id);

    int insert(Friends record);

    int insertSelective(Friends record);

    Friends selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(Friends record);

    int updateByPrimaryKey(Friends record);

    List<Friends> selectByUserId(@Param("userId") Long currentUserId);

    void deleteByUserIdAndFriendId(@Param("userId") Long currentUserId, @Param("friendId") Long friendId);

    List<Friends> selectByFriendsId(@Param("friendId") Long currentUserId);

}